package javaSE.LibrarySystem.User;

import javaSE.LibrarySystem.Book.BookList;
import javaSE.LibrarySystem.operation.IOperation;

public abstract class User {
    protected String name;

    protected IOperation[] iOperations;//该用户对象的功能数组

    public User(String name) {
        this.name = name;
    }

    //显示菜单
    public abstract int menu();

    public void doWork(int choice, BookList bookList){//进入菜单后可以进行相应的功能
        iOperations[choice].work(bookList); //选择功能进行相应的图书管理
    }
}
